import request from '@/utils/request'

// 获取列表
export function getMonthCarListAPI(params) {
    return request({
        url: '/parking/card/list',
        method: 'GET',
        params: params
    })
}

export function addCarCardAPI(obj) {
    return request({
        url: '/parking/card',
        method: 'POST',
        data: obj
        // params:{}
    })
}

export function delCarCardAPI(id) {
    return request({
        url: '/parking/card/' + id,
        method: 'DELETE'
    })
}

export function getCarCardDetail(id) {
    return request({
        url: '/parking/card/detail/' + id,
        method: 'GET'
    })
}

export function editCarCard(obj){
    return request({
        url: '/parking/card/edit',
        method: 'PUT',
        data:obj
    })
}

export function getCarCardDetaiAPI(id){
    return request({
        url:'/parking/card/'+id,
        method:'GET'
    })
}

export function rechargeAPI(obj){
    return request({
        url:'/parking/card/recharge',
        method:'POST',
        data:obj
    })
}

export function getCarListAPI(){
    return request({
        url:'/parking/statistics/current',
        method:'GET'
    })
}

export function getCarPayListAPI(params) {
    return request({
      url: '/parking/payment/list',
      method: 'GET',
      params: params
    })
  }